//
//  LBViewController.m
//  LBUIKit
//
//  Created by redye on 06/06/2017.
//  Copyright (c) 2017 redye. All rights reserved.
//

#import "LBViewController.h"
#import <LBUIKit/LBUIKit.h>

@interface LBViewController ()

@end

@implementation LBViewController

- (void)viewDidLoad
{
    CGFloat buttonWidth = CGRectGetWidth([UIScreen mainScreen].bounds) / 4;
    CGFloat buttonHeight = 100;
    LBCustomButton *button = [[LBCustomButton alloc] init];
    [button into:@"tg_tb_wx_01" title:@"微信" frame:CGRectMake(20, 100, buttonWidth, buttonHeight)];
    button.iconImgView.center = CGPointMake(buttonWidth / 2, button.iconImgView.center.y);
    button.titleLabel.center = CGPointMake(buttonWidth / 2, button.titleLabel.center.y);
    [button.titleLabel setFont:[UIFont systemFontOfSize:13]];
    button.backgroundColor = [UIColor lightGrayColor];
    [button addTarget:self action:@selector(buttonClick) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:button];
}

- (void)buttonClick {
    NSLog(@"点击按钮");
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
